; Music of Troll (1988) (U.S. Gold)
; Ripped by Megachur the 18/03/2009

	write "TROLL.BIN"

music_date_rip	equ &1239
music_adr	equ &716a
first_theme	equ 1
last_theme	equ 33	; 1 -> 33

	read "music_header_v1_0.asm"

.l7171 equ $ + 7
.l716f equ $ + 5
.l716e equ $ + 4
.l716d equ $ + 3
.l716b equ $ + 1
.l716a
	db #01,#00,#00,#00,#01,#00,#00,#00
.l7179 equ $ + 7
.l7177 equ $ + 5
.l7173 equ $ + 1
	db #00,#01,#00,#00,#00,#00,#00,#00
.l7181 equ $ + 7
.l7180 equ $ + 6
.l717e equ $ + 4
.l717d equ $ + 3
	db #00,#01,#00,#10,#00,#10,#0f,#01
.l7187 equ $ + 5
.l7186 equ $ + 4
.l7183 equ $ + 1
	db #01,#00,#00,#00,#00,#00,#00,#00
.l7190 equ $ + 6
	db #00,#00,#01,#00,#00,#00,#00,#00
.l7199 equ $ + 7
.l7197 equ $ + 5
	db #00,#00,#0a,#00,#70,#00,#20,#0f
.l71a0 equ $ + 6
.l719f equ $ + 5
	db #01,#0a,#00,#00,#00,#00,#00,#00
.l71a9 equ $ + 7
	db #00,#00,#00,#04,#00,#00,#00,#00
.l71b0 equ $ + 6
	db #00,#00,#00,#00,#00,#70,#00,#20
.l71b6 equ $ + 4
.l71b2
	db #0f,#01,#02,#00,#00
;
.play_music
;
	call l71e2
	xor a
	call l71cb
	ld a,#19
	call l71cb
	ld a,#32
	call l71cb
	jp l84cf
.l71cb
	ld (l834d),a
	call l8060
	call l7ffa
	call l8020
	call l7fa9
	ret
	call l82e0
	call l84cf
	ret
.l71e2
	ld a,(l716a)
	or a
	jr z,l71fb
;
.init_music
;
	ld (l71b6),a
	xor a
	ld (l716a),a
	ld (l834c),a
	ld a,#38
	ld (l8517),a
	call l82e0
	ret
.l71fb
	ld a,(l71b6)
	or a
	jp z,l7212
	ld (l728c),a
	xor a
	ld (l834a),a
	ld (l834b),a
	ld (l8349),a
	ld (l71b6),a
.l7212
	ld a,(l728c)
	add a
	ret z
	ld l,a
	ld h,#00
	ld de,l7223
	add hl,de
	ld e,(hl)
	inc hl
	ld d,(hl)
	ex de,hl
	jp (hl)
.l7223
	dw l8307,l728e,l729b,l7297
	dw l72bb,l72c4,l72e4,l7304
	dw l7329,l7324,l7349,l734f
	dw l7358,l7358,l7383,l73ae
	dw l73bc,l73bc,l73d3,l73c5
	dw l73ca,l73d3,l73f8,l73f8
	dw l7438,l7418,l7418,l7438
	dw l7458,l7458,l7478,l7498
	dw l749e,l74a7,l74c7
.l7269
	db #00,#00,#60,#60,#00,#60,#48,#18
	db #60,#60,#00,#00,#80,#40,#40,#00
	db #00,#00,#30,#00,#00,#2e,#60,#23
	db #3d,#60,#23,#3d,#60,#30,#30,#00
.l728c equ $ + 3
	db #00,#21,#00,#00,#00
.l728e
	ld a,#18
	ld b,#08
	ld c,#18
	jp l80e8
.l7297
	xor a
	ld (l834c),a
.l729b
	ld e,#04
	call l8308
	ld e,#18
	ld hl,l76d5
	call l7f48
	ld e,#0c
	ld hl,l7675
	call l7f5e
	ld e,#00
	ld hl,l7735
	call l7f62
	jp l8332
.l72bb
	ld a,#18
	ld b,#20
	ld c,#18
	jp l80e8
.l72c4
	ld e,#04
	call l8308
	ld e,#18
	ld hl,l789d
	call l7f48
	ld e,#0c
	ld hl,l77f5
	call l7f5e
	ld e,#00
	ld hl,l7795
	call l7f62
	jp l8332
.l72e4
	ld e,#04
	call l8308
	ld e,#18
	ld hl,l7855
	call l7f48
	ld e,#0c
	ld hl,l77f5
	call l7f5e
	ld e,#00
	ld hl,l7795
	call l7f62
	jp l8332
.l7304
	ld e,#04
	call l8308
	ld e,#18
	ld hl,l7645
	call l7f48
	ld e,#00
	ld hl,l765d
	call l7f62
	ld e,#18
	ld hl,l765d
	call l7f5e
	jp l8332
.l7324
	ld a,#03
	ld (l834c),a
.l7329
	ld e,#04
	call l8308
	ld e,#18
	ld hl,l7525
	call l7f48
	ld e,#00
	ld hl,l7585
	call l7f62
	ld e,#0c
	ld hl,l75e5
	call l7f5e
	jp l8332
.l7349
	ld a,#01
	ld (l728c),a
	ret
.l734f
	ld a,#18
	ld b,#08
	ld c,#18
	jp l80e8
.l7358
	ld e,#05
	call l8308
	ld e,#18
	ld hl,l79ed
	call l7f48
	ld e,#18
	ld hl,l78fd
	call l7f5e
	ld a,c
	and #01
	jr nz,l7380
	ld a,c
	srl a
	srl a
	ld c,a
	ld e,#00
	ld hl,l79bd
	call l7f62
.l7380
	jp l8332
.l7383
	ld e,#05
	call l8308
	ld e,#18
	ld hl,l7a6d
	call l7f48
	ld e,#18
	ld hl,l797d
	call l7f5e
	ld a,c
	and #01
	jr nz,l73ab
	ld a,c
	srl a
	srl a
	ld c,a
	ld e,#00
	ld hl,l79dd
	call l7f62
.l73ab
	jp l8332
.l73ae
	ld a,(l834c)
	xor #03
	ld (l834c),a
	ld a,#0c
	ld (l728c),a
	ret
.l73bc
	ld a,#18
	ld b,#20
	ld c,#10
	jp l80e8
.l73c5
	xor a
	ld (l728c),a
	ret
.l73ca
	ld a,#18
	ld b,#08
	ld c,#10
	jp l80e8
.l73d3
	ld a,#05
	ld (l834c),a
	ld e,#04
	call l8308
	ld e,#18
	ld hl,l7ca0
	call l7f48
	ld e,#00
	ld hl,l7c6f
	call l7f62
	ld e,#18
	ld hl,l7c6f
	call l7f5e
	jp l8332
.l73f8
	ld e,#04
	call l8308
	ld e,#18
	ld hl,l7ebd
	call l7f48
	ld e,#00
	ld hl,l7e5a
	call l7f62
	ld e,#0c
	ld hl,l7d91
	call l7f5e
	jp l8332
.l7418
	ld e,#04
	call l8308
	ld e,#18
	ld hl,l7ebd
	call l7f48
	ld e,#00
	ld hl,l7e5a
	call l7f62
	ld e,#0c
	ld hl,l7df7
	call l7f5e
	jp l8332
.l7438
	ld e,#04
	call l8308
	ld e,#18
	ld hl,l7d11
	call l7f48
	ld e,#00
	ld hl,l7cd1
	call l7f62
	ld e,#00
	ld hl,l7d51
	call l7f5e
	jp l8332
.l7458
	ld e,#04
	call l8308
	ld e,#18
	ld hl,l7bd9
	call l7f48
	ld e,#00
	ld hl,l7b43
	call l7f62
	ld e,#0c
	ld hl,l7ae0
	call l7f5e
	jp l8332
.l7478
	ld e,#04
	call l8308
	ld e,#18
	ld hl,l7c3c
	call l7f48
	ld e,#00
	ld hl,l7ba6
	call l7f62
	ld e,#0c
	ld hl,l7aad
	call l7f5e
	jp l8332
.l7498
	ld a,#16
	ld (l728c),a
	ret
.l749e
	ld a,#18
	ld b,#08
	ld c,#08
	jp l80e8
.l74a7
	ld e,#06
	call l8308
	ld e,#18
	ld hl,l74cd
	call l7f5b
	ld e,#0c
	ld hl,l74f9
	call l7f62
	ld e,#0c
	ld hl,l74cd
	call l7f5e
	jp l8332
.l74c7
	ld a,#13
	ld (l716a),a
	ret
.l74cd
	db #0c,#00,#0c,#11,#00,#11,#13,#00
	db #14,#00,#00,#11,#00,#00,#11,#17
	db #00,#18,#00,#00,#14,#00,#00,#11
	db #00,#00,#0b,#00,#00,#00,#00,#00
	db #00,#0c,#00,#0c,#0c,#00,#0e,#10
.l74f9 equ $ + 4
	db #00,#11,#00,#00,#0c,#00,#0c,#11
	db #00,#11,#0f,#00,#00,#0d,#00,#00
	db #0c,#00,#0b,#00,#00,#08,#00,#00
	db #05,#00,#00,#0c,#00,#00,#0b,#00
	db #00,#00,#00,#00,#00,#11,#00,#07
	db #0c,#00,#0c,#0c,#00,#05,#00,#00
.l7525
	db #2d,#00,#00,#2d,#00,#00,#00,#00
	db #00,#00,#00,#00,#00,#00,#2d,#2d
	db #00,#00,#2d,#00,#00,#00,#00,#00
	db #2a,#00,#00,#2a,#00,#00,#00,#00
	db #00,#2a,#00,#2a,#2a,#00,#00,#2a
	db #00,#00,#3a,#00,#00,#2a,#00,#00
	db #2f,#00,#00,#2f,#00,#00,#00,#00
	db #00,#00,#00,#2f,#00,#00,#28,#28
	db #00,#00,#28,#00,#00,#00,#00,#00
	db #2d,#00,#00,#2d,#00,#00,#00,#00
	db #00,#2d,#00,#2d,#29,#00,#00,#29
	db #00,#00,#28,#00,#00,#28,#00,#00
.l7585
	db #0d,#00,#0d,#0d,#00,#0d,#00,#00
	db #00,#00,#00,#00,#0d,#00,#00,#0d
	db #00,#0c,#0d,#00,#0d,#0c,#00,#0a
	db #0a,#00,#00,#0a,#00,#05,#00,#00
	db #05,#0a,#00,#00,#0a,#00,#00,#0a
	db #00,#00,#08,#00,#00,#05,#00,#00
	db #07,#00,#00,#08,#00,#00,#0a,#00
	db #00,#07,#00,#00,#0c,#00,#00,#08
	db #00,#00,#0a,#00,#00,#0c,#00,#0a
	db #0d,#00,#00,#00,#00,#00,#0d,#00
	db #00,#0d,#00,#00,#09,#00,#00,#09
	db #00,#09,#08,#00,#00,#00,#00,#00
.l75e5
	db #19,#00,#14,#16,#00,#19,#00,#00
	db #00,#00,#00,#00,#00,#00,#00,#19
	db #00,#16,#19,#00,#16,#19,#00,#00
	db #1a,#00,#00,#16,#00,#16,#00,#00
	db #00,#00,#00,#00,#00,#00,#00,#16
	db #00,#00,#14,#00,#00,#11,#00,#00
	db #13,#00,#16,#19,#00,#1d,#00,#00
	db #1d,#00,#00,#00,#12,#00,#14,#18
	db #00,#1b,#00,#00,#1b,#00,#00,#00
	db #19,#00,#00,#19,#00,#00,#19,#00
	db #1b,#1c,#00,#19,#15,#00,#00,#15
	db #00,#00,#14,#00,#00,#00,#00,#00
.l7645
	db #1d,#00,#1d,#1d,#00,#00,#2a,#00
	db #2a,#2a,#00,#00,#2f,#00,#00,#2f
	db #00,#00,#28,#00,#38,#28,#00,#28
.l765d
	db #0d,#00,#0a,#0d,#00,#00,#0a,#00
	db #0a,#0a,#00,#0a,#0f,#00,#00,#0f
	db #00,#00,#08,#00,#0a,#0c,#00,#00
.l7675
	db #14,#00,#00,#13,#00,#14,#15,#00
	db #00,#14,#00,#15,#16,#00,#15,#16
	db #00,#18,#00,#00,#14,#00,#00,#18
	db #19,#00,#1b,#1c,#00,#1d,#00,#00
	db #16,#18,#00,#16,#18,#00,#10,#11
	db #00,#00,#16,#00,#00,#00,#00,#14
	db #13,#00,#16,#19,#00,#1d,#00,#00
	db #1d,#00,#00,#1d,#12,#00,#14,#18
	db #00,#1b,#00,#00,#1b,#00,#00,#1b
	db #19,#00,#19,#00,#00,#19,#00,#00
	db #16,#00,#00,#00,#18,#00,#1b,#18
	db #00,#16,#00,#00,#15,#14,#00,#13
.l76d5
	db #2d,#00,#2d,#2d,#00,#00,#29,#00
	db #29,#29,#00,#00,#43,#00,#43,#43
	db #00,#28,#00,#00,#00,#00,#00,#28
	db #21,#00,#21,#21,#00,#25,#00,#00
	db #00,#00,#00,#25,#45,#00,#00,#45
	db #00,#62,#00,#00,#00,#00,#00,#62
	db #67,#00,#67,#67,#00,#67,#00,#00
	db #00,#00,#00,#67,#6c,#00,#6c,#6c
	db #00,#6c,#00,#00,#00,#00,#00,#00
	db #4a,#00,#4a,#4a,#00,#4a,#00,#00
	db #67,#00,#00,#67,#4f,#00,#4f,#4f
	db #00,#4f,#00,#00,#6c,#00,#00,#00
.l7735
	db #0d,#00,#00,#00,#00,#00,#09,#00
	db #00,#00,#00,#09,#03,#00,#00,#03
	db #00,#00,#08,#00,#00,#00,#00,#00
	db #01,#00,#00,#00,#00,#00,#05,#00
	db #00,#00,#00,#05,#0a,#00,#00,#02
	db #00,#05,#0a,#00,#00,#07,#00,#00
	db #03,#00,#00,#00,#00,#00,#05,#00
	db #00,#07,#00,#00,#08,#00,#00,#07
	db #00,#00,#05,#00,#00,#03,#00,#00
	db #03,#00,#00,#03,#00,#00,#05,#00
	db #00,#07,#00,#00,#0a,#00,#00,#03
	db #00,#00,#06,#00,#00,#08,#00,#00
.l7795
	db #0d,#00,#08,#00,#00,#0d,#00,#00
	db #00,#00,#00,#00,#00,#00,#0d,#00
	db #00,#08,#0d,#00,#08,#0d,#00,#00
	db #09,#00,#04,#00,#00,#09,#00,#00
	db #00,#00,#00,#00,#00,#00,#09,#00
	db #00,#04,#09,#00,#04,#09,#00,#00
	db #08,#00,#03,#00,#00,#08,#00,#00
	db #00,#00,#00,#00,#00,#00,#0a,#00
	db #00,#08,#0a,#00,#0a,#08,#00,#00
	db #0d,#00,#00,#00,#00,#0d,#00,#00
	db #0d,#0d,#00,#0d,#09,#00,#09,#00
	db #00,#09,#08,#00,#00,#00,#00,#00
.l77f5
	db #19,#00,#00,#00,#00,#19,#00,#00
	db #00,#00,#00,#00,#00,#00,#1b,#00
	db #00,#19,#1b,#00,#19,#1b,#00,#00
	db #19,#00,#00,#00,#00,#19,#00,#00
	db #00,#00,#00,#00,#00,#00,#1b,#00
	db #00,#19,#1b,#00,#19,#1b,#00,#00
	db #14,#00,#00,#00,#00,#14,#00,#00
	db #00,#00,#00,#00,#00,#00,#16,#00
	db #00,#14,#16,#00,#14,#16,#00,#00
	db #19,#00,#00,#00,#00,#19,#00,#00
	db #19,#19,#00,#19,#15,#00,#15,#00
	db #00,#15,#14,#00,#00,#00,#00,#00
.l7855
	db #2d,#00,#00,#00,#00,#2d,#00,#00
	db #00,#00,#00,#00,#00,#00,#00,#00
	db #00,#00,#00,#00,#00,#00,#00,#00
	db #67,#00,#00,#00,#00,#67,#00,#00
	db #00,#00,#00,#00,#00,#00,#00,#00
	db #00,#00,#00,#00,#00,#00,#00,#00
	db #28,#00,#00,#00,#00,#28,#00,#00
	db #00,#00,#00,#00,#00,#00,#00,#00
	db #00,#00,#00,#00,#00,#00,#00,#00
.l789d
	db #2d,#00,#00,#00,#00,#2d,#00,#00
	db #00,#00,#00,#00,#00,#00,#00,#00
	db #00,#00,#00,#00,#00,#00,#00,#00
	db #6d,#00,#00,#00,#00,#6d,#00,#00
	db #00,#00,#00,#00,#00,#00,#00,#00
	db #00,#00,#00,#00,#00,#00,#00,#00
	db #6c,#00,#00,#00,#00,#6c,#00,#00
	db #00,#00,#00,#00,#00,#00,#00,#00
	db #00,#00,#00,#00,#00,#00,#00,#00
	db #2d,#00,#00,#00,#00,#2d,#00,#00
	db #2d,#2d,#00,#2d,#29,#00,#29,#00
	db #00,#29,#28,#00,#00,#00,#00,#00
.l78fd
	db #12,#00,#12,#00,#12,#0f,#12,#00
	db #0f,#00,#0f,#0f,#00,#0d,#0d,#00
	db #0d,#00,#0d,#00,#0d,#0a,#0d,#00
	db #08,#00,#08,#08,#00,#06,#00,#06
	db #08,#00,#00,#06,#00,#00,#00,#00
	db #08,#06,#08,#06,#00,#06,#08,#00
	db #0b,#00,#0b,#00,#0b,#08,#0b,#00
	db #0b,#08,#0b,#08,#00,#08,#06,#00
	db #12,#00,#12,#00,#12,#0f,#12,#00
	db #0f,#00,#0f,#0f,#00,#0d,#0d,#00
	db #0d,#00,#0d,#00,#0d,#0a,#0d,#00
	db #08,#00,#08,#08,#00,#06,#00,#06
	db #0a,#0b,#0c,#00,#0d,#0d,#0f,#11
	db #00,#11,#0f,#00,#0c,#00,#08,#00
	db #0d,#00,#00,#00,#00,#00,#00,#00
	db #00,#00,#00,#00,#00,#00,#00,#00
.l797d
	db #08,#08,#08,#00,#0c,#00,#0c,#0d
	db #00,#0d,#0d,#00,#0f,#00,#12,#00
	db #12,#00,#10,#00,#10,#00,#0f,#10
	db #00,#00,#00,#00,#00,#00,#00,#00
	db #00,#06,#0b,#00,#0b,#00,#0b,#0b
	db #00,#0a,#00,#08,#00,#00,#0a,#00
	db #0d,#00,#0b,#00,#0b,#00,#0a,#0b
	db #00,#00,#00,#00,#00,#00,#00,#00
.l79bd
	db #0d,#12,#06,#12,#0b,#12,#06,#12
	db #0d,#12,#06,#12,#0b,#12,#0f,#0c
	db #0d,#12,#06,#12,#0b,#12,#0c,#15
	db #0d,#16,#0d,#11,#12,#00,#00,#00
.l79dd
	db #14,#18,#12,#18,#10,#19,#14,#13
	db #12,#17,#12,#16,#17,#12,#12,#0c
.l79ed
	db #00,#00,#6a,#00,#6a,#00,#6a,#00
	db #6a,#00,#6a,#6a,#00,#6a,#26,#00
	db #00,#00,#2b,#00,#2b,#00,#2b,#00
	db #2b,#00,#2b,#2b,#00,#2b,#69,#00
	db #00,#00,#6a,#00,#6a,#00,#6a,#00
	db #6a,#00,#6a,#6a,#00,#6a,#26,#00
	db #00,#00,#2b,#00,#2b,#00,#2b,#00
	db #2b,#00,#00,#00,#69,#00,#00,#00
	db #00,#00,#6a,#00,#6a,#00,#6a,#00
	db #6a,#00,#6a,#6a,#00,#6a,#26,#00
	db #00,#00,#2b,#00,#2b,#00,#2b,#00
	db #69,#00,#69,#69,#00,#69,#69,#00
	db #00,#00,#4a,#00,#4a,#00,#4a,#00
	db #6c,#00,#6c,#6c,#00,#6c,#28,#00
	db #00,#00,#6a,#00,#6a,#00,#6a,#6a
	db #00,#00,#00,#00,#00,#00,#00,#00
.l7a6d
	db #00,#00,#6c,#00,#6c,#00,#6c,#00
	db #6c,#00,#6c,#6c,#00,#6c,#28,#00
	db #00,#00,#4d,#00,#4d,#00,#4d,#00
	db #4d,#00,#4d,#4d,#00,#4d,#4d,#00
	db #00,#00,#2b,#00,#2b,#00,#2b,#00
	db #6a,#00,#6a,#6a,#00,#6a,#26,#00
	db #00,#00,#2b,#00,#2b,#00,#2b,#00
	db #2b,#00,#00,#00,#69,#00,#00,#00
.l7aad
	db #00,#00,#00,#13,#00,#00,#11,#00
	db #13,#00,#00,#00,#00,#00,#00,#00
	db #00,#13,#14,#00,#00,#11,#00,#13
	db #00,#00,#14,#00,#00,#00,#00,#00
	db #00,#00,#00,#00,#00,#00,#00,#00
	db #00,#00,#00,#00,#00,#00,#00,#00
.l7ae0 equ $ + 3
	db #00,#00,#00,#12,#00,#14,#15,#00
	db #00,#15,#00,#00,#15,#00,#00,#15
	db #00,#00,#15,#00,#15,#15,#00,#14
	db #00,#00,#12,#00,#00,#00,#15,#00
	db #00,#12,#00,#15,#00,#00,#00,#00
	db #00,#00,#00,#00,#14,#15,#00,#00
	db #14,#00,#12,#00,#00,#00,#14,#00
	db #00,#10,#00,#14,#00,#00,#00,#00
	db #00,#00,#00,#00,#12,#14,#00,#00
	db #12,#00,#10,#00,#00,#14,#00,#00
	db #00,#00,#00,#00,#00,#00,#00,#00
	db #00,#00,#00,#00,#00,#00,#00,#00
.l7b43 equ $ + 6
	db #00,#00,#00,#00,#00,#00,#03,#00
	db #04,#06,#00,#06,#09,#00,#00,#0b
	db #00,#00,#0c,#00,#0d,#06,#00,#06
	db #09,#00,#00,#0b,#00,#00,#0c,#00
	db #0d,#06,#00,#06,#09,#00,#00,#0b
	db #00,#00,#0c,#00,#0d,#06,#00,#06
	db #09,#00,#00,#0b,#00,#00,#0c,#00
	db #0d,#01,#00,#01,#04,#00,#00,#06
	db #00,#00,#07,#00,#08,#01,#00,#01
	db #04,#00,#00,#06,#00,#00,#07,#00
	db #08,#01,#00,#01,#04,#00,#00,#06
	db #00,#00,#07,#00,#08,#01,#00,#01
	db #04,#00,#00,#06,#00,#00,#07,#00
.l7ba6 equ $ + 1
	db #08,#05,#00,#04,#03,#00,#03,#07
	db #00,#00,#08,#00,#00,#09,#00,#0a
	db #03,#00,#03,#07,#00,#00,#08,#00
	db #00,#0a,#00,#00,#08,#00,#08,#0c
	db #00,#00,#0d,#00,#00,#0e,#00,#00
	db #0f,#00,#08,#06,#00,#00,#04,#00
.l7bd9 equ $ + 4
	db #00,#03,#00,#00,#46,#00,#00,#00
	db #00,#00,#46,#00,#46,#00,#00,#00
	db #46,#00,#46,#00,#00,#00,#46,#00
	db #46,#00,#00,#00,#46,#00,#46,#00
	db #00,#00,#46,#00,#46,#00,#00,#00
	db #46,#00,#46,#00,#00,#00,#46,#00
	db #46,#00,#00,#00,#46,#00,#41,#00
	db #00,#00,#41,#00,#41,#00,#00,#00
	db #41,#00,#41,#00,#00,#00,#41,#00
	db #41,#00,#00,#00,#41,#00,#41,#00
	db #00,#00,#41,#00,#41,#00,#00,#00
	db #41,#00,#41,#00,#00,#00,#41,#00
.l7c3c equ $ + 7
	db #41,#00,#00,#00,#41,#00,#41,#29
	db #00,#29,#00,#00,#00,#23,#00,#23
	db #00,#00,#00,#23,#00,#23,#00,#00
	db #00,#23,#00,#23,#00,#00,#00,#23
	db #00,#28,#00,#00,#00,#28,#00,#28
	db #00,#00,#00,#28,#00,#28,#00,#00
	db #00,#28,#00,#28,#00,#00,#00,#28
.l7c6f equ $ + 2
	db #00,#28,#04,#01,#00,#00,#04,#00
	db #00,#08,#00,#00,#0d,#00,#00,#09
	db #00,#00,#00,#00,#00,#08,#00,#06
	db #04,#00,#03,#01,#00,#00,#04,#00
	db #00,#08,#00,#00,#0d,#00,#00,#09
	db #00,#09,#00,#00,#09,#08,#00,#00
.l7ca0 equ $ + 3
	db #00,#00,#00,#00,#41,#00,#00,#00
	db #00,#00,#00,#00,#00,#00,#00,#00
	db #29,#00,#00,#00,#00,#00,#28,#00
	db #00,#6c,#00,#00,#41,#00,#00,#00
	db #00,#00,#00,#00,#00,#00,#00,#00
	db #29,#00,#29,#00,#00,#29,#28,#00
.l7cd1 equ $ + 4
	db #00,#00,#00,#00,#00,#03,#00,#04
	db #06,#00,#06,#09,#00,#00,#0b,#00
	db #0b,#0c,#00,#0d,#06,#00,#06,#09
	db #00,#00,#0b,#00,#0b,#0c,#00,#0d
	db #01,#00,#01,#04,#00,#00,#06,#00
	db #06,#00,#07,#00,#08,#00,#08,#0c
	db #00,#00,#0f,#00,#0f,#0c,#00,#0f
	db #0d,#00,#0d,#0b,#00,#00,#09,#00
.l7d11 equ $ + 4
	db #09,#07,#00,#08,#00,#41,#00,#00
	db #46,#00,#46,#00,#00,#00,#00,#00
	db #46,#46,#00,#46,#46,#00,#46,#00
	db #00,#00,#00,#00,#46,#46,#00,#46
	db #41,#00,#41,#00,#00,#00,#00,#00
	db #41,#41,#00,#41,#28,#00,#28,#00
	db #00,#00,#00,#00,#28,#00,#28,#00
	db #4d,#00,#4d,#00,#00,#00,#00,#00
.l7d51 equ $ + 4
	db #41,#41,#00,#41,#00,#17,#00,#15
	db #00,#00,#00,#00,#00,#00,#00,#00
	db #00,#15,#00,#15,#15,#00,#19,#1e
	db #00,#21,#00,#00,#21,#00,#00,#14
	db #14,#00,#19,#1c,#00,#20,#00,#00
	db #20,#00,#00,#20,#14,#00,#18,#1b
	db #00,#1e,#00,#00,#1c,#1b,#00,#19
	db #00,#00,#00,#00,#00,#00,#00,#00
.l7d91 equ $ + 4
	db #00,#00,#00,#00,#00,#00,#0d,#10
	db #00,#0d,#10,#00,#0d,#00,#00,#08
	db #00,#00,#0d,#10,#00,#0d,#10,#00
	db #0d,#00,#00,#08,#00,#00,#0d,#10
	db #00,#0d,#10,#00,#00,#10,#00,#00
	db #10,#00,#0d,#10,#00,#12,#10,#00
	db #0f,#00,#00,#00,#00,#00,#0c,#0f
	db #00,#0c,#0f,#00,#00,#0c,#00,#00
	db #08,#00,#0c,#0f,#00,#0c,#0f,#00
	db #0c,#00,#00,#08,#00,#00,#00,#00
	db #00,#0c,#0f,#00,#00,#0f,#00,#00
	db #0f,#00,#0d,#0f,#00,#10,#0f,#00
	db #0d,#00,#00,#00,#00,#00,#00,#10
.l7df7 equ $ + 2
	db #00,#0d,#13,#00,#14,#13,#00,#00
	db #14,#00,#00,#13,#00,#00,#14,#00
	db #00,#13,#00,#00,#14,#00,#10,#00
	db #00,#0d,#00,#00,#0d,#13,#00,#00
	db #14,#00,#00,#13,#00,#00,#14,#00
	db #12,#00,#00,#00,#00,#00,#00,#00
	db #00,#00,#13,#00,#14,#13,#12,#13
	db #14,#00,#00,#18,#00,#00,#1b,#00
	db #1e,#1c,#1b,#1c,#1b,#00,#00,#18
	db #00,#00,#14,#00,#13,#14,#00,#13
	db #12,#00,#10,#00,#00,#0f,#00,#00
	db #0d,#00,#00,#00,#00,#00,#00,#00
.l7e5a equ $ + 5
	db #00,#00,#00,#00,#00,#06,#00,#08
	db #01,#00,#01,#04,#00,#00,#06,#00
	db #00,#07,#00,#08,#01,#00,#01,#04
	db #00,#00,#06,#00,#00,#07,#00,#08
	db #01,#00,#01,#04,#00,#00,#06,#00
	db #00,#07,#00,#08,#08,#00,#08,#0c
	db #00,#00,#0f,#00,#00,#0c,#00,#0f
	db #08,#00,#08,#0c,#00,#00,#0f,#00
	db #00,#0c,#00,#0f,#08,#00,#08,#0c
	db #00,#00,#0f,#00,#00,#0c,#00,#0f
	db #08,#00,#08,#06,#00,#00,#04,#00
	db #04,#03,#00,#00,#01,#00,#01,#04
	db #00,#00,#06,#00,#00,#07,#00,#08
.l7ebd
	db #00,#00,#00,#4d,#00,#4d,#00,#00
	db #00,#00,#00,#4d,#4d,#00,#4d,#4d
	db #00,#4d,#00,#00,#00,#00,#00,#4d
	db #4d,#00,#4d,#4d,#00,#00,#4d,#00
	db #4d,#4d,#00,#4d,#4d,#00,#4d,#4d
	db #00,#6c,#00,#00,#00,#6c,#00,#00
	db #6c,#00,#6c,#00,#00,#6c,#00,#00
	db #00,#00,#00,#6c,#6c,#00,#6c,#6c
	db #00,#6c,#00,#00,#00,#00,#00,#6c
	db #6c,#00,#6c,#6c,#00,#00,#6c,#00
	db #00,#6c,#00,#6c,#6c,#00,#6c,#4d
	db #00,#4d,#00,#00,#4d,#00,#00,#00
	db #00,#00,#00
	ld b,#00
	ld a,c
	and #07
	ld c,a
	ld a,#38
	ld (l8517),a
	ld a,e
	ld hl,l7f40
	add hl,bc
	and (hl)
	jr z,l7f3c
	xor a
	ld (l8518),a
	ld a,#30
	ld (l8517),a
.l7f3c
	ld a,e
	and (hl)
	ret z
	ret
.l7f40
	add b
	ld b,b
	jr nz,l7f54
	ex af,af'
	inc b
	ld (bc),a
.l7f48 equ $ + 1
	ld bc,#32af
	ld c,l
	add e
	add hl,bc
	ld a,(hl)
	and a
	ret z
	push af
	and #f0
.l7f54 equ $ + 1
	ld (l717d),a
	pop af
	and #0f
	jr l7f69
.l7f5b
	xor a
	jr l7f64
.l7f5e
	ld a,#19
	jr l7f64
.l7f62
	ld a,#32
.l7f64
	ld (l834d),a
	add hl,bc
	ld a,(hl)
.l7f69
	ld (l8345),a
	and #7f
	ret z
	ld hl,l834c
	add (hl)
	add e
	add #06
	ld de,(l834d)
	ld hl,l716f
	add hl,de
	add a
	add a
	ld e,a
	ld d,#00
	ld (hl),e
	inc hl
	ld (hl),d
	ld a,(l8345)
	bit 7,a
	jr nz,l7f91
	inc hl
	ld (hl),e
	inc hl
	ld (hl),d
.l7f91
	ld hl,l7179
	ld de,(l834d)
	add hl,de
	xor a
	ld (hl),a
	inc hl
	ld (hl),a
	ld hl,l7181
	add hl,de
	ld a,#01
	ld (hl),a
	dec hl
	ld a,#ff
	ld (hl),a
	ret
.l7fa9
	di
	ld (l8345),sp
	ld bc,(l834d)
	ld hl,l716f
	add hl,bc
	ld sp,hl
	pop hl
	pop de
	and a
	sbc hl,de
	dec sp
	dec sp
	pop hl
	pop bc
	jr z,l7fca
	jr c,l7fc7
	add hl,bc
	jr l7fca
.l7fc7
	and a
	sbc hl,bc
.l7fca
	ld (l8347),hl
	pop de
	add hl,de
	ld de,#0030
	and a
	ld b,#00
.l7fd5
	inc b
	sbc hl,de
	jr nc,l7fd5
	add hl,de
	add hl,hl
	ld de,l846f
	add hl,de
	ld e,(hl)
	inc hl
	ld d,(hl)
.l7fe3
	srl d
	rr e
	djnz l7fe3
	inc sp
	inc sp
	push de
	ld hl,(l8347)
	dec sp
	dec sp
	dec sp
	dec sp
	push hl
	ld sp,(l8345)
	ei
	ret
.l7ffa
	ld de,(l834d)
	ld hl,l7181
	add hl,de
	dec (hl)
	ret nz
	inc hl
	ld a,(hl)
	dec hl
	ld (hl),a
	dec hl
	ld a,#0f
	cp (hl)
	ret z
	inc (hl)
	ld e,(hl)
	ld d,#00
	ld b,#00
	dec hl
	ld c,(hl)
	push hl
	ld hl,l834f
	add hl,bc
	add hl,de
	ld a,(hl)
	pop hl
	dec hl
	ld (hl),a
	ret
.l8020
	ld hl,l7179
	ld bc,(l834d)
	add hl,bc
	ld e,(hl)
	inc hl
	ld d,(hl)
	inc de
	ld (hl),d
	dec hl
	ld (hl),e
	ld bc,#0000
	inc hl
	inc hl
	ld a,(hl)
	and a
	push hl
	ld h,#00
	ld l,a
	sbc hl,de
	pop hl
	inc hl
	inc hl
	jr nc,l8054
	push hl
	ld a,e
	and #0f
	or (hl)
	ld c,a
	ld hl,l83bf
	add hl,bc
	ld a,(hl)
	ld c,a
	and a
	pop hl
	jp p,l8054
	ld b,#ff
.l8054
	dec hl
	dec hl
	dec hl
	dec hl
	dec hl
	dec hl
	dec hl
	dec hl
	ld (hl),c
	inc hl
	ld (hl),b
	ret
.l8060
	ld a,(l728c)
	or a
	ret nz
	ld hl,l716b
	ld bc,(l834d)
	add hl,bc
	inc (hl)
	inc hl
	jr nz,l8079
	inc (hl)
	jr nz,l8079
	inc hl
	ld a,(hl)
	inc hl
	jr l807d
.l8079
	inc hl
	inc hl
	ld a,(hl)
	ld (hl),b
.l807d
	and a
	ret z
	ld c,a
	sla c
	sla c
	sla c
	sla c
	rl b
	dec hl
	dec hl
	dec hl
	ex de,hl
	ld hl,l8121
	add hl,bc
	ldi
	ldi
	ldi
	inc de
	ldi
	ldi
	ldi
	ldi
	ldi
	ldi
	inc de
	inc de
	inc de
	inc de
	inc de
	inc de
	ldi
	ldi
	ldi
	inc de
	ldi
	inc de
	inc de
	ldi
	ldi
	call l82d1
	jp l7f91
.l80c0
	ld b,#00
	ld d,#00
	ld hl,l7173
	add hl,de
	ld c,a
	ex de,hl
	ld hl,l8109
	add hl,bc
	ldi
	ldi
	inc de
	inc de
	inc de
	inc de
	inc de
	inc de
	ldi
	ldi
	ldi
	inc de
	ldi
	inc de
	inc de
	ldi
	ldi
	ret
.l80e8
	ld (l8345),bc
	ld e,#00
	call l80c0
	ld a,(l8346)
	ld e,#19
	call l80c0
	ld a,(l8345)
	ld e,#32
	call l80c0
	ld a,(l728c)
	inc a
	ld (l71b6),a
	ret
.l8109
	db #01,#00,#01,#00,#50,#10,#01,#01
	db #01,#00,#0a,#00,#70,#20,#05,#01
	db #04,#00,#00,#00,#70,#20,#02,#01
.l8121
	db #01,#00,#00,#00,#70,#20,#01,#01
	db #01,#00,#0a,#00,#50,#20,#03,#01
	db #ff,#ff,#00,#00,#00,#00,#00,#04
	db #00,#08,#00,#00,#00,#01,#00,#00
	db #91,#fd,#01,#e5,#00,#5a,#00,#15
	db #00,#01,#00,#50,#20,#01,#01,#00
	db #21,#ff,#01,#83,#00,#1f,#00,#01
	db #00,#00,#00,#20,#20,#08,#01,#00
	db #3b,#ff,#01,#97,#00,#6f,#00,#01
	db #00,#00,#00,#40,#20,#02,#01,#00
	db #37,#ff,#01,#e0,#00,#fe,#00,#09
	db #00,#08,#00,#50,#20,#03,#01,#00
	db #a5,#ff,#01,#0a,#00,#0b,#00,#08
	db #00,#10,#00,#50,#20,#01,#01,#00
	db #9c,#ff,#01,#fa,#00,#ff,#00,#34
	db #00,#00,#00,#30,#20,#01,#01,#00
	db #37,#ff,#01,#e0,#00,#18,#00,#16
	db #00,#00,#00,#20,#20,#03,#01,#00
	db #9c,#ff,#01,#3a,#00,#0d,#00,#37
	db #00,#00,#00,#20,#20,#01,#01,#00
	db #c8,#ff,#01,#36,#00,#03,#00,#0c
	db #00,#00,#00,#00,#60,#01,#01,#00
	db #f7,#ff,#0e,#10,#00,#6e,#00,#08
	db #00,#00,#00,#00,#60,#01,#01,#00
	db #a5,#ff,#01,#77,#00,#dd,#00,#02
	db #00,#00,#00,#30,#60,#04,#01,#00
	db #a5,#ff,#01,#db,#00,#79,#00,#02
	db #00,#00,#00,#30,#60,#02,#01,#00
	db #a7,#ff,#01,#36,#00,#03,#00,#04
	db #00,#00,#00,#70,#30,#01,#08,#00
	db #e6,#ff,#01,#1f,#00,#33,#00,#01
	db #00,#08,#00,#00,#60,#03,#01,#00
	db #e6,#ff,#01,#33,#00,#15,#00,#01
	db #00,#08,#00,#00,#60,#03,#01,#00
	db #00,#ff,#01,#9a,#00,#f4,#00,#01
	db #00,#10,#00,#80,#20,#03,#01,#00
	db #00,#ff,#01,#fe,#00,#90,#00,#01
	db #00,#10,#00,#80,#20,#03,#01,#00
	db #d5,#ff,#01,#83,#00,#dd,#00,#03
	db #00,#08,#00,#50,#60,#03,#01,#00
	db #d5,#ff,#01,#e7,#00,#79,#00,#03
	db #00,#08,#00,#50,#60,#03,#01,#00
	db #a7,#ff,#01,#df,#00,#a2,#00,#00
	db #00,#04,#00,#20,#20,#02,#01,#00
	db #d2,#ff,#01,#0b,#00,#de,#00,#01
	db #00,#00,#00,#20,#20,#04,#01,#00
	db #d2,#ff,#01,#de,#00,#a1,#00,#01
	db #00,#00,#00,#20,#20,#04,#01,#00
	db #00,#ff,#01,#36,#00,#04,#00,#e4
	db #00,#10,#00,#50,#20,#01,#01,#00
	db #f3,#ff,#01,#3f,#00,#33,#00,#df
	db #00,#08,#00,#50,#60,#03,#01,#00
	db #e9,#ff,#01,#21,#00,#01,#00,#df
	db #00,#00,#00,#20,#20,#01,#01,#00
.l82d1
	ld a,(l7183)
	xor #39
	ld (l8517),a
	ld a,(l7171)
	ld (l8518),a
	ret
.l82e0
	xor a
	ld (l717e),a
	ld (l7197),a
	ld (l71b0),a
	ld (l716d),a
	ld (l7186),a
	ld (l719f),a
	ld (l716e),a
	ld (l7187),a
	ld (l71a0),a
	ld a,#0f
	ld (l7180),a
	ld (l7199),a
	ld (l71b2),a
.l8307
	ret
.l8308
	ld bc,(l834a)
	ld a,(l8349)
	inc a
	cp e
	jp nz,l8316
	ld a,#00
.l8316
	ld (l8349),a
	ret z
	pop bc
	ret
.l831c
	ld bc,(l728c)
	ld hl,l7269
	add hl,bc
	ld c,(hl)
	ld hl,(l834a)
	inc hl
	ld (l834a),hl
	and a
	sbc hl,bc
	ret z
	pop bc
	ret
.l8332
	call l831c
	ld a,(l728c)
	inc a
	ld (l71b6),a
	ret
	call l831c
	ld a,e
	ld (l71b6),a
	ret
.l834c equ $ + 7
.l834b equ $ + 6
.l834a equ $ + 5
.l8349 equ $ + 4
.l8347 equ $ + 2
.l8346 equ $ + 1
.l8345
	db #00,#00,#00,#00,#00,#00,#00,#00
.l834f equ $ + 2
.l834d
	db #00,#00,#00,#00,#00,#00,#00,#00
	db #00,#00,#00,#00,#00,#00,#00,#00
	db #00,#00,#0f,#0f,#07,#08,#09,#0a
	db #0b,#0b,#0b,#0b,#0b,#0b,#0b,#0b
	db #0b,#0b,#0f,#0c,#0d,#0c,#0b,#0a
	db #09,#08,#07,#06,#05,#04,#03,#02
	db #01,#00,#0f,#0d,#0b,#09,#07,#05
	db #03,#01,#00,#00,#00,#00,#00,#00
	db #00,#00,#01,#02,#03,#04,#05,#06
	db #07,#08,#09,#0a,#0b,#0c,#0d,#0e
	db #0f,#00,#0f,#02,#0f,#03,#0f,#04
	db #0f,#05,#0f,#06,#0f,#07,#0f,#08
	db #0f,#09,#03,#06,#09,#0c,#0e,#0f
	db #0f,#0f,#0d,#0b,#09,#07,#05,#03
.l83bf equ $ + 2
	db #01,#00,#00,#00,#00,#00,#00,#00
	db #00,#00,#00,#00,#00,#00,#00,#00
	db #00,#00,#14,#00,#14,#1c,#00,#14
	db #1c,#00,#14,#1c,#00,#14,#1c,#00
	db #14,#1c,#10,#00,#10,#1c,#00,#10
	db #1c,#00,#10,#1c,#00,#10,#1c,#00
	db #10,#1c,#08,#00,#08,#1c,#00,#08
	db #1c,#00,#08,#1c,#00,#08,#1c,#00
	db #08,#1c,#0c,#00,#0c,#1c,#00,#0c
	db #1c,#00,#0c,#1c,#00,#0c,#1c,#00
	db #0c,#1c,#01,#02,#01,#00,#ff,#fe
	db #ff,#00,#01,#02,#01,#00,#ff,#fe
	db #ff,#00,#0c,#00,#0c,#18,#00,#0c
	db #18,#00,#0c,#18,#00,#0c,#18,#00
	db #0c,#18,#01,#00,#30,#00,#01,#00
	db #30,#00,#01,#00,#30,#00,#01,#00
	db #30,#00,#00,#00,#00,#04,#04,#04
	db #00,#00,#00,#04,#04,#04,#00,#00
	db #00,#04,#00,#00,#00,#08,#08,#08
	db #00,#00,#00,#08,#08,#08,#00,#00
	db #00,#08,#00,#00,#00,#0c,#0c,#0c
	db #00,#00,#00,#0c,#0c,#0c,#00,#00
.l846f equ $ + 2
	db #00,#0c,#00,#10,#c5,#0f,#8b,#0f
	db #52,#0f,#1a,#0f,#e3,#0e,#ac,#0e
	db #76,#0e,#41,#0e,#0d,#0e,#d9,#0d
	db #a6,#0d,#74,#0d,#43,#0d,#12,#0d
	db #e2,#0c,#b3,#0c,#84,#0c,#56,#0c
	db #29,#0c,#fd,#0b,#d1,#0b,#a5,#0b
	db #7a,#0b,#50,#0b,#27,#0b,#fe,#0a
	db #d6,#0a,#ae,#0a,#87,#0a,#60,#0a
	db #3a,#0a,#14,#0a,#ef,#09,#cb,#09
	db #a7,#09,#83,#09,#61,#09,#3e,#09
	db #1c,#09,#fb,#08,#da,#08,#b9,#08
	db #99,#08,#7a,#08,#5b,#08,#3c,#08
	db #1e,#08
.l84cf
	ld hl,(l7177)
	ld a,#00
	call l8519
	ld hl,(l7190)
	ld a,#02
	call l8519
	ld hl,(l71a9)
	ld a,#04
	call l8519
	ld a,(l8518)
	ld c,a
	ld a,#06
	call l8525
	ld a,(l717e)
	ld c,a
	ld a,#08
	call l8525
	ld a,(l7197)
	ld c,a
	ld a,#09
	call l8525
	ld a,(l71b0)
	ld c,a
	ld a,#0a
	call l8525
	ld a,(l8517)
	and #3f
	ld c,a
	ld a,#07
	call l8525
	ret
.l8518 equ $ + 1
.l8517
	jr c,l8519
.l8519
	ld c,l
	ld e,a
	call l8525
	ld a,e
	inc a
	ld c,h
	call l8525
	ret
.l8525
	push bc
	di
	ld b,#f4
	out (c),a
	ld b,#f6
	in a,(c)
	or #c0
	out (c),a
	and #3f
	out (c),a
	ld b,#f4
	out (c),c
	ld b,#f6
	ld c,a
	or #80
	out (c),a
	out (c),c
	ei
	pop bc
	ret

;org #5143
;ld a,#01
;ld (#716a),a

;
.game_name
	db "Troll",0
.game_year
	db "1988",0
.game_publisher
	db "U.S. Gold",0
.music_author
	db "",0
.music_comment
	db "",0

	read "music_end_v1_0.asm"
